package com.techsoul.common.core.pojo.vo;

import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.experimental.Accessors;
import com.fasterxml.jackson.annotation.JsonFormat;

import java.util.Date;
import java.io.Serializable;
import java.util.List;

/**
 * 组织机构 Vo
 *
 * @author liuen
 * @date 2020-12-04
 */
@Data
@Accessors(chain = true)
public class OrgVo implements Serializable {

    private static final long serialVersionUID = 1L;

    @ApiModelProperty("子节点列表")
    private List<OrgVo> children;
    @ApiModelProperty("仓库编码")
    private String warehouseCode;
    @ApiModelProperty("ID（人为编码，唯一性）")
    private String id;

    @ApiModelProperty("PID，父级编号")
    private String pid;

    @ApiModelProperty("祖级ID集合（多个用逗号隔开）")
    private String ancestorIds;

    @ApiModelProperty("祖级名称集合（多个用逗号隔开）")
    private String ancestorNames;

    @ApiModelProperty("机构名称（允许重复）")
    private String orgName;

    @ApiModelProperty("机构全称（不允许重复）")
    private String orgFullName;

    @ApiModelProperty("机构类型，数据字典sys_org_type")
    private String orgType;

    @ApiModelProperty("负责人")
    private String leader;

    @ApiModelProperty("办公电话")
    private String phone;

    @ApiModelProperty("电子邮箱")
    private String email;

    @ApiModelProperty("联系地址")
    private String address;

    @ApiModelProperty("邮政编码")
    private String postalCode;

    @ApiModelProperty("层次级别，根为0")
    private Integer treeLevel;

    @ApiModelProperty("是否为叶子节点（数据字典sys_yn_type，默认1-是）")
    private String isLeaf;

    @ApiModelProperty("排序")
    private Integer treeSort;

    @ApiModelProperty("状态")
    private String status;

    @ApiModelProperty("备注")
    private String remark;

    @ApiModelProperty("是否有效（数据字典sys_yn_type，默认1-是）")
    private String isValid;

    @ApiModelProperty("创建人")
    private String createBy;

    @ApiModelProperty("创建时间")
    @JsonFormat(pattern = "yyyy-MM-dd")
    private Date createTime;

    @ApiModelProperty("更新人")
    private String updateBy;

    @ApiModelProperty("更新时间")
    @JsonFormat(pattern = "yyyy-MM-dd")
    private Date updateTime;

    @ApiModelProperty("创建人名称")
    private String createByName;

    @ApiModelProperty("更新人名称")
    private String updateByName;

    @ApiModelProperty("父机构名称")
    private String parentName;

}
